import React, { PropsWithChildren } from "react";
import { AmountItem4Amount, AmountItem4Title, AmountItem4Wrap } from "./styles";

export interface AmountItem4Props extends PropsWithChildren {
  title?: string;
  /**
   *  金额
   */
  amount?: number;
  type?: number;
}

const AmountItem = ({ title, amount = 0, type = 1 }: AmountItem4Props) => {
  return (
    <AmountItem4Wrap className={"type" + type}>
      <AmountItem4Amount>{amount}%</AmountItem4Amount>
      <AmountItem4Title>{title}</AmountItem4Title>
    </AmountItem4Wrap>
  );
};

export default AmountItem;
